package com.itcast.yygh.hosp.mongo;

import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserRepository extends MongoRepository<User,String> {
    List<User> findByNameLike(String name);

    List<User> findByName(String name);

    List<User> findByNameAndAge(String name, int age);

    List<User> findByNameOrAge(String name, int age);
}
